SET_SOURCE_FILES(PTAM_MIXED_SRC_FILES
	GLWindow2.cc
	GLWindowMenu.cc
	System_ros.cc 
	ATANCamera.cc
	KeyFrame.cc
	MapPoint.cc
	Map.cc
	SmallBlurryImage.cc
	ShiTomasi.cc 
	HomographyInit.cc 
	MapMaker.cc 
	Bundle.cc 
	PatchFinder.cc
	RelocaliserSCARF.cc
	MiniPatch.cc
	MapViewer.cc
  RelocaliserSBI.cc
	Tracker.cc
	main_ros.cc
  PolygonalMesh.cpp
  SVD.cpp
  Bloomenthal.cpp
  PointSet.cpp
  OctTree.cpp
  RBF.cpp
  PBCG.cpp
  Scarf.cpp
  Combination.cpp
  #FivePointTemporary.cpp
  PoseEstimator.cpp
  DynamicObject.cpp
  SE3GaussianPDF.cpp
)

SET_SOURCE_FILES(PTAM_MIXED_CALIB_SRC_FILES
  GLWindow2.cc
  GLWindowMenu.cc
  CalibImage.cc
  CalibCornerPatch.cc
  ATANCamera.cc
  CameraCalibrator_ros.cc
)

SET_SOURCE_FILES(WEEDER_MIXED_FILES
  ATANCamera.cc
  RBF.cpp
	GLWindow2.cc
	GLWindowMenu.cc
  PolygonalMesh.cpp
  SVD.cpp
  Bloomenthal.cpp
  PointSet.cpp
  OctTree.cpp
  PBCG.cpp
  Weeder.cpp
  SVM.cpp
  Scarf.cpp
)

SET_SOURCE_FILES(UNDISTORTER_MIXED_SRC_FILES
	ATANCamera.cc
	ImageUndistorter.cpp
)

INCLUDE_DIRECTORIES(
#  ${BFL_INCLUDE_DIR}
  ${ARMADILLO_INCLUDE_DIR}
  ../../external/arboretum/include
  ../../external/ARToolKit
  ${EIGEN3_INCLUDE_DIR}
)

rosbuild_add_executable(mixedptam ${PTAM_MIXED_SRC_FILES})
if(CMAKE_SYSTEM_PROCESSOR MATCHES "i686")
rosbuild_add_compile_flags(mixedptam -march=native)
endif(CMAKE_SYSTEM_PROCESSOR MATCHES "i686")
target_link_libraries(mixedptam
    ${ARMADILLO_LIBRARY}
${MRPT_LIBS}
	${GVARS3_LIBRARY}
	${CVD_LIBRARY}
  ${CXCORE_LIBRARY}
  ${CV_LIBRARY}
  ${HIGHGUI_LIBRARY}
  ${Boost_FILESYSTEM_LIBRARY}
  ${Boost_THREAD_LIBRARY}
)
target_link_libraries(mixedptam arboretum)
target_link_libraries(mixedptam ARToolKit)


rosbuild_add_executable(mixedptamcalib ${PTAM_MIXED_CALIB_SRC_FILES})
if(CMAKE_SYSTEM_PROCESSOR MATCHES "i686")
rosbuild_add_compile_flags(mixedptamcalib -march=native)
endif(CMAKE_SYSTEM_PROCESSOR MATCHES "i686")
target_link_libraries(mixedptamcalib
	${GVARS3_LIBRARY}
	${CVD_LIBRARY}
  	${CXCORE_LIBRARY}
  	${CV_LIBRARY}
  	${HIGHGUI_LIBRARY}
)



#PIXHAWK_EXECUTABLE(px_mixed_ptam ${PTAM_MIXED_SRC_FILES})

#PIXHAWK_LINK_LIBRARIES(px_mixed_ptam 
#	${ARMADILLO_LIBRARY}
#	${GVARS3_LIBRARY}
#	${CVD_LIBRARY}
#  ${CXCORE_LIBRARY}
 # ${CV_LIBRARY}
#  ${HIGHGUI_LIBRARY}
 # ${Boost_FILESYSTEM_LIBRARY}
 # ${Boost_THREAD_LIBRARY}
 # lcmext
 # arboretum
 # ARToolKit
#)

#PIXHAWK_EXECUTABLE(px_mixed_ptam_calib ${PTAM_MIXED_CALIB_SRC_FILES})
#PIXHAWK_LINK_LIBRARIES(px_mixed_ptam_calib
#	${GVARS3_LIBRARY}
#	${CVD_LIBRARY}
#  ${CXCORE_LIBRARY}
 # ${CV_LIBRARY}
 # ${HIGHGUI_LIBRARY}
#  lcmext
 #)

#PIXHAWK_EXECUTABLE(px_mixed_weeder ${WEEDER_MIXED_FILES})
#PIXHAWK_LINK_LIBRARIES(px_mixed_weeder
#	${GVARS3_LIBRARY}
##	${CVD_LIBRARY}
 # ${CXCORE_LIBRARY}
#  ${CV_LIBRARY}
#  ${Boost_PROGRAM_OPTIONS_LIBRARY}
 # ${HIGHGUI_LIBRARY}
 # lcmext
#)

#PIXHAWK_EXECUTABLE(px_mixed_undistorter ${UNDISTORTER_MIXED_SRC_FILES})
#PIXHAWK_LINK_LIBRARIES(px_mixed_undistorter
#	${GVARS3_LIBRARY}
#	${CVD_LIBRARY}
#  ${Boost_PROGRAM_OPTIONS_LIBRARY}
#  ${CXCORE_LIBRARY}
 # ${CV_LIBRARY}
#  ${HIGHGUI_LIBRARY}
# )

#PIXHAWK_EXECUTABLE(px_gabor Gabor.cpp)
#PIXHAWK_LINK_LIBRARIES(px_gabor
#	${GVARS3_LIBRARY}
#	${CVD_LIBRARY}
#  ${Boost_PROGRAM_OPTIONS_LIBRARY}
#  ${CXCORE_LIBRARY}
#  ${CV_LIBRARY}
#  ${HIGHGUI_LIBRARY}
#)

#PIXHAWK_EXECUTABLE(px_watershed WaterShed.cpp)
#PIXHAWK_LINK_LIBRARIES(px_watershed
#	${CVD_LIBRARY}
#  ${Boost_PROGRAM_OPTIONS_LIBRARY}
#  ${CXCORE_LIBRARY}
#  ${CV_LIBRARY}
#  ${HIGHGUI_LIBRARY}
#)

